package com.sky.controller.user;

import com.sky.dto.UserLoginDTO;
import com.sky.result.Result;
import com.sky.service.UserService.UserService;
import com.sky.vo.UserLoginVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

@RestController
@RequestMapping("/user/user")
@Api(tags = "小程序用户相关接口")
public class UserController {
    @Resource
  private UserService userServicel;

    @PostMapping("/login")
    @ApiOperation("用户登录")
    public Result<UserLoginVO> loginPrograms(@RequestBody UserLoginDTO userLoginDTO){
        Result<UserLoginVO> userLoginVOResult = userServicel.loginPrograms(userLoginDTO);
       return userLoginVOResult;
    }
}
